package adv331;

import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStream;

/**
 * @author oldliu
 * @since 1.0
 */
public class OutputStreamTest {
    public static void main(String[] args) {
        //write
        try {
            OutputStream out=new FileOutputStream("D:\\temp\\java76.txt",true);
            out.write('\r');
            out.write('\n');

            out.write("We change lives".getBytes());
            out.write(65);
            out.write(66);
            out.write(67);
            out.write(97);
            // out.write(10000);
            byte b[]={72,73,74};
            out.write(b);
            out.close();//有隐患
        } catch (IOException e) {
            e.printStackTrace();
        }
    }
}
